
from user import views
from rest_framework.routers import SimpleRouter
router = SimpleRouter()
from django.urls import path

# http://127.0.0.1:8000/api/v1/user/  user/check_model/
# http://127.0.0.1:8000/api/v1/user/dep_register/reg_department/
# http://127.0.0.1:8000/api/v1/user/doc_register/register/
# http://127.0.0.1:8000/api/v1/user/mobile/get_mobile/
# http://127.0.0.1:8000/api/v1/user/login/login/

router.register('dep_register', views.UserRegisterView, 'dep_register')
router.register('doc_register', views.UserRegisterView, 'doc_register')
router.register('mobile', views.UserRegisterView, 'mobile')
router.register('login', views.UserLoginView, 'login')

# http://127.0.0.1:8000/api/v1/user/password/send_sms/
# http://127.0.0.1:8000/api/v1/user/userinfo/user_forget/
# http://127.0.0.1:8000/api/v1/user/password/check_pwd/
# http://127.0.0.1:8000/api/v1/user/mobile/check_mobile/
# http://127.0.0.1:8000/api/v1/user/code/code_cache/
# http://127.0.0.1:8000/api/v1/user/head/upload_head/
# 忘记密码相关接口
router.register('password', views.UserForgetView, 'password')
router.register('userinfo', views.UserForgetView, 'userinfo')
router.register('mobile', views.UserForgetView, 'mobile')
router.register('code', views.UserForgetView, 'code')
router.register('head', views.HeadFileView,'head')


# 修改密码
# http://127.0.0.1:8000/api/v1/user/password/update_pwd/
router.register('password', views.UpdatePassword,"password")

# http://127.0.0.1:8000/api/v1/user/get_user/
router.register('get_user', views.GetUserView, 'get_user')


# 查询药品和种类接口
# http://127.0.0.1:8000/api/v1/user/medicine_type/
router.register('medicine_type', views.MedicineTypeView, 'medicine_type')



# 药品管理界面
# http://127.0.0.1:8000/api/v1/user/yao/
router.register('yao', views.MedicinView, 'yao')
router.register('ke', views.DepartView, 'ke')
# http://127.0.0.1:8000/api/v1/user/ke_name/
router.register('ke_name', views.DepartmentView, 'ke_name')
# # 搜索接口 http://127.0.0.1:8000/api/v1/user/medsearch/
router.register('medsearch', views.MedicineSearchView, 'medsearch')

router.register('departinfo',views.DepartmentInfoView,'departinfo')
# 药品开单  http://127.0.0.1:8000/api/v1/user/get_medicine/
router.register('get_medicine', views.GetMedicineView, 'get_medicine')




urlpatterns = [

]
urlpatterns += router.urls



